package TiAnGo;

/**
 * @Author czl
 * @Date 2024-03-22
 */
public class BoyThread extends Thread{

    private String name;

    private  Box box;


    public BoyThread (String  name , Box box){
        this.name=name;
        this.box=box;
    }

    @Override
    public void run() {
        while (true){
            box.put(name,new Fruit());
        }
    }
}
